package com.sam.gui.activity;

import android.content.Intent;
import android.os.Bundle;
import android.webkit.*;

import com.sam.gui.base.BaseWebActivity;
import com.sam.ui.base.activity.BaseActivity;

/**
 * Created by Administrator on 2015-10-27.
 */
public class AppointmentAcitivity extends BaseWebActivity {

    @Override
    protected void initView() {
        super.initView();
        setContentUrl("index.php?c=user&a=user_wz");
    }

    @JavascriptInterface
    public void wzjlxq(){
        Intent intent = new Intent(this, DiagnosisRecordWebActivity.class);
        startActivity(intent);
    }

    @JavascriptInterface
    public void set_password(){
        Intent intent = new Intent(this, ChangePwdWebActivity.class);
        startActivity(intent);
    }

    @JavascriptInterface
    public void new_yy(){  //新预约
        Intent intent = new Intent(this, MakeAppointmentWebActivity.class);
        startActivity(intent);
    }

    @JavascriptInterface
    public void view_yuyue(String req_id, String dopost){
        Intent intent = new Intent(this, AppointmentDetailsWebActivity.class);
        Bundle bundle = new Bundle();
        bundle.putString("req_id", req_id);
        bundle.putString("dopost", dopost);
        intent.putExtras(bundle);
        startActivity(intent);
    }

    @JavascriptInterface
    public void ap_view(String ap_id){
        Intent intent = new Intent(this, BespeakSpareTimeWebActivity.class);
        Bundle bundle = new Bundle();
        bundle.putString("ap_id", ap_id);
        intent.putExtras(bundle);
        startActivity(intent);
    }

    @JavascriptInterface
    public void comment_ap(String ap_id){
        Intent intent = new Intent(this, AppointmentEvaluationWebActivity.class);
        Bundle bundle = new Bundle();
        bundle.putString("ap_id", ap_id);
        intent.putExtras(bundle);
        startActivity(intent);
    }

    @JavascriptInterface
    public void ts_ap(String ap_id){
        Intent intent = new Intent(this, ComplaintAppointmentWebActivity.class);
        Bundle bundle = new Bundle();
        bundle.putString("ap_id", ap_id);
        intent.putExtras(bundle);
        startActivity(intent);
    }

    @JavascriptInterface
    public void submitSuccess(){
        finish();
    }
}
